7b3b9076b04517f70358cca8d1950caae67f9663,server/src/com/cloud/api/ApiDispatcher.java,ApiDispatcher,dispatch,#BaseCmd#Map#,130

Before Change


            }else {
                errorMsg = "Internal error";
                s_logger.error("Exception while executing " + cmd.getClass().getSimpleName() + ":", t);
                if (UserContext.current().getAccount() == null || UserContext.current().getAccount().getType() == Account.ACCOUNT_TYPE_ADMIN)
                    throw new ServerApiException(BaseCmd.INTERNAL_ERROR, t.getMessage());
                else
                    throw new ServerApiException(BaseCmd.INTERNAL_ERROR, BaseCmd.USER_ERROR_MESSAGE);

After Change


            } else {
                errorMsg = "Internal error";
                s_logger.error("Exception while executing " + cmd.getClass().getSimpleName() + ":", t);
                if (UserContext.current().getAccount().getType() == Account.ACCOUNT_TYPE_ADMIN)
                    throw new ServerApiException(BaseCmd.INTERNAL_ERROR, t.getMessage());
                else
                    throw new ServerApiException(BaseCmd.INTERNAL_ERROR, BaseCmd.USER_ERROR_MESSAGE);
            }